package com.kaiupup.study.util;

import com.kaiupup.study.request.VerificationCodeDTO;

/**
 * @projectName: kaiupup-online-taxi
 * @package: com.kaiupup.study.util
 * @className: RedisPrefixUtils
 * @author: kaiupup
 * @description: TODO
 * @date: 2024/1/19 19:00
 * @version: 1.0
 */
public class RedisPrefixUtils {

    //乘客验证码前缀
    public static String verificationCodePrefix = "verification-code-";

    //token存储前缀
    public static String tokenPrefix = "token-";

    //黑名单设备号
    public static String blackDeviceCodePrefix = "black-device-";

    //根据手机号生成key
    public static String generatorkeyByPhone(String phone,String identity){
        return verificationCodePrefix + identity+"-"+phone;
    }

    public static String generatorTokenKey(String phone, String identity, String tokenType) {
        return verificationCodePrefix + identity + "-" + tokenType + "-" + phone;
    }







}
